package com.devunion.bogdan.view.event;

import com.devunion.bogdan.model.project.Project;

import javax.swing.*;
import java.util.EventObject;

/**
 * @author Viktar Liaskovich
 */
public class ProjectTreeBuilderEvent extends EventObject {
    private Project project;
    private JTree projectTree;

    /**
     * Constructs a prototypical Event.
     *
     * @param source The object on which the Event initially occurred.
     * @throws IllegalArgumentException if source is null.
     * @param project the project
     */
    public ProjectTreeBuilderEvent(Object source, Project project, JTree projectTree) {
        super(source);
        this.project = project;
        this.projectTree = projectTree;
    }

    public Project getProject() {
        return project;
    }

    public JTree getProjectTree() {
        return projectTree;
    }
}
